package utll;

public class ResultSubmit {
        public static Result success(Object data){
            Result result = new Result();
            result.setCode(200);
            result.setData(data);
            result.setMessage("操作成功");
            return result;
        }

        public static Result error(String message){
            Result result = new Result();
            result.setCode(-1);
            result.setMessage(message);
            return result;
        }

        public static Result fail(){
            Result result = new Result();
            result.setCode(-1);
            result.setMessage("服务器错误，请联系运维人员");
            return result;
        }
}
